﻿/*============================================
 * 类名 :OperatorNode
 * 描述 :操作符节点
 *   
 * 创建时间: 2009-11-3 16:44:09
 *============================================*/
using System;
using System.Collections.Generic;

using System.Text;

namespace 命题证明
{
    /// <summary>操作符节点</summary> 
    class OperatorNode : Node
    {
        public OperatorNode() { }
        public OperatorNode( Operator op )
        {
            this.Operator = op;
        }
        public OperatorNode( Node left , Node right , Operator op )
        {
            this.Left = left;
            this.Right = right;
            this.Operator = op;
        }

        /// <summary>获取或设置这个节点存储的操作符</summary>
        public Operator Operator { get; set; }

        public override string ToString()
        {
            return ExpressionFactory.ConvertToMiddle( this );
        }   

    }
}
